<?php
include "koneksi.php";
$query="select file_content,file_type from gambar order by id desc limit 1";
$data=mysql_query($query);
$data=mysql_fetch_array($data);

$content=$data[0];
$type=$data[1];

header("Content-type: $type");   // parsing ke mime tipe


echo $content;  
?>